<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=<{$Charset}>">
<link rel="stylesheet" type="text/css" href="css/main.css">
<script language="javascript" src="<{$JS_PATH}>js/general.js"></script>
<script language="javascript" src="<{$JS_PATH}>js/admin.js"></script>
</head>

<body leftmargin="10" topmargin="10">
<table width="100%" border="0" cellpadding="2" cellspacing="6"><tr><td><table width="100%" border="0" cellpadding="0" cellspacing="0" class="guide"><tr>
  <td><div align="left"><a href="#" onClick="parent.main.location='home.php';return false;">控制台</a>&nbsp;&raquo; 添加/修改产品</div>
  </td>
</tr>
</table>
      <form name="productmodfrm" enctype="multipart/form-data" method="post" action="<{$smarty.server.PHP_SELF}>">
        <input type="hidden" name="id" value="<{$P.id}>" />
        <input type="hidden" name="oldimgname" value="<{$P.picture}>">
        <table width="100%"  border="0" cellpadding="1" cellspacing="1" class="tableborder">
			<tr class="header">
			  <td colspan="6">产品库</td>
			</tr>
          <{if $P.id}>
          <tr>
            <td align="center" class="altbg1">编号                  
            <td colspan="3" class="altbg2"><span class="menu">
              <{$P.id}>
            </span></td>
          </tr>
          <{else}>
          <{/if}>
          <tr>
            <td align="center" class="altbg1"><font color=red>*</font> 商品分类</td>
            <td class="altbg2"><select name="product[sort_id]" id="sort_id">
                <{html_options options=$ProductSorts selected=$P.sort_id}>
              </select></td>
            <td class="altbg1"><font color=red>*</font> 商品名称</td>
            <td class="altbg2"><input name=product[name] type=text id="product[name]" value="<{$P.name}>"></td>
          </tr>
          
          <tr>
            <td class="altbg1" align="center">商品型号</td>
            <td class="altbg2"><input name=product[sn] type=text id="product[sn]" value="<{$P.sn}>"></td>
            <td class="altbg1">原产地</td>
            <td class="altbg2"><input name=product[produce_area] type=text id="product[produce_area]" value="<{$P.produce_area}>"></td>
          </tr>
          
          <tr>
            <td class="altbg1" align="center"><span class="bwhitefont">规格</span>
            <td class="altbg2"><span class="menu">
              <input name=product[spec] type=text id="product[spec]" value="<{$P.spec}>">
            </span></td>
            <td class="altbg1">价格</td>
            <td class="altbg2"><input name=product[price] type=text id="product[price]" value="<{$P.price}>"></td>
          </tr>
          
          <tr>
            <td class="altbg1" align="center"><span class="bwhitefont">包装说明</span>
            <td colspan="3" class="altbg2"><span class="menu">
              <input name=product[packing_content] type=text id="product[packing_content]" value="<{$P.packing_content}>">
            </span></td>
          </tr>
          <tr>
            <td align="center" valign="top" class="altbg1"><span class="bwhitefont">详细说明 </span>
            <td colspan="3" class="altbg2"><textarea name=product[content] 

cols=45 rows=6 id="product[content]"><{$P.content}></textarea></td>
          </tr>
          <tr>
            <td class="altbg1" align="center"><span class="bwhitefont">产品图片 </span>
            <td colspan="3" class="altbg2"><img id="uploadpic" src="<{if $P.picture!=""}><{$attachment_dir}><{$P.picture}><{else}>../media/default/big.jpg<{/if}>"  border="0" width="400" height="255" alt="看到这个,表明你的图片出错了!"></td>
          </tr>
          <tr>
            <td class="altbg1" align="center"><span class="bwhitefont">上传图片 </span>
            <td colspan="3" class="altbg2"><input type="file" name="pic" id="uploadfile" 

size=40 onChange="preview()">
<br />
              （产品图片要求：文件小于200K，400*250为最佳格式,JPG格式或GIF格式均可）</td>
          </tr>
          <tr class="altbg1">
            <td colspan="4" align="center">
			<table border="0" cellpadding="5" cellspacing="0" class="button">
                <tr>
                  <td><input  name="save" type=submit id="save" value=" 保存 " class="btn_mouseout" onMouseOver="this.className='btn_mouseover'" onMouseOut="this.className='btn_mouseout'"></td>
                  <td><input  name="checkin_product" type="submit" id="checkin_product" value=" 审核通过 " class="btn_mouseout" onMouseOver="this.className='btn_mouseover'" onMouseOut="this.className='btn_mouseout'"></td>
                  <td><input  name="checkout_product" type="submit" id="checkout_product" value=" 审核不通过 " class="btn_mouseout" onMouseOver="this.className='btn_mouseover'" onMouseOut="this.className='btn_mouseout'"></td>
                  <td><input  name="return" type="submit" id="return" value=" 返回页面 " class="btn_mouseout" onMouseOver="this.className='btn_mouseover'" onMouseOut="this.className='btn_mouseout'"></td>
                </tr>
          </table>          </tr>
        </table>
      </form></td></tr></table>
<br /><br />
</body>
</html>

